 <?
if (!defined('baseinfo')) {
    exitdata();
    
}   
?>
<div class="wrprCovPf">
	<div class="covPf">
		<a href="<?=$data['userdata']['bannerimgarray']['newpath']?>" target="_blank" ><img src="<?=$data['userdata']['sbannerimgarray']['newpath']?>" alt="img" width="960" height="300"></a>
	</div>
	<div class="wrpCovPf">
		<div class="ovlPf clBgBt1"></div>
		<div class="wrprInfoPf">
			<div class="wrpFlwMsgEdtPf">
                <?php 
                if($data['userdata']['userid']!=$data['user']['userid'])
                {
                ?>
				<div class="fMEPf" title="Follow" onclick="followfunction(0,<?if($data['userdata']['userid']){echo $data['userdata']['userid'];}else{echo 0;}?>);" >
					<span class="ico icoUnFlwPf <?php if($data['userdata']['checkfollow']===3){echo "icoFlwWaitPf";} else if($data['userdata']['checkfollow']){ echo "icoFlwPf"; }?>"></span>
				</div>
                <?php
                }
                ?>
                <?php 
                if(($data['userdata']['userid']!=$data['user']['userid'])&&$data['user']['userid'])
                {
                ?>
				<div class="fMEPf" onclick="location.href='<?=baseinfo.'/'.$data['user']['username'].'/messages?userid='.$data['userdata']['userid']?>'" title="Message">
					<span class="ico icoMsgPf"></span>
				</div>
                <?}?>
                <?php 
                if($data['userdata']['userid']==$data['user']['userid'])
                {
                ?>
					<? if(NameDmconnex=="Canonlife"){  ?>
					<?} else {?>
						<div class="fMEPf" onclick="location.href='<?=baseinfo.'/setting'?>'" title="Edit Profile">
							<span class="ico icoEdtPf"></span>
						</div>
					<?}?>
                <?php
                }
                ?>
			</div>
			<? if(NameDmconnex=="Canonlife"){  ?>
				<div class="fMEPf editPfCn" onclick="location.href='<?=baseinfo.'/setting'?>'" title="Edit Profile">
					<span class="ico3 icoStPf"></span>
				</div>
			<?} else {?>	
			<?}?>
			<div class="wrpNumFlwPf clTxtPf">
				<div class="wrpNumFlwerPf" onclick="redirectto(baseinfo+'/<?=$data['userdata']['username']?>/followers')">
					<span class="fs11"><?=$data['userdata']['countfollower'];?></span><br>
					<span class="txtUp fs01">Followers</span>
				</div>
				<div class="wrpNumFlwngPf" onclick="redirectto(baseinfo+'/<?=$data['userdata']['username']?>/following')">
					<span class="fs11"><?=$data['userdata']['countfollowing'];?></span><br>
					<span class="txtUp fs01">Following</span>
				</div>
			</div>
		</div>
	</div>
	<div class="wrprImgPf">
		<div class="wrpImgPf">
			<a href="<?php 
                if($data['userdata']['userid']==$data['user']['userid'])
                {
               echo baseinfo.'/setting';}else{ echo $data['userdata']['imguser']['newpath'];}?>" target="_blank"><img src="<?
               if($data['userdata']['simguser']['newpath']&&$data['userdata']['simguser']['width']>174)
               {
               
               
               
               echo $data['userdata']['simguser']['newpath'];
               
               
               
               }else if($data['userdata']['imguser']['newpath'])
               {
               echo $data['userdata']['imguser']['newpath'];
               
               }
               
               
               else{ echo baseinfo."/img/user1.jpg";}?>" alt="img" width="175" height="175"></a>
               <? if(NameDmconnex=="Canonlife"){  ?>
				<div class="fMEPf editCn" onclick="location.href='<?=baseinfo.'/setting'?>'" title="Edit Profile">
					<span class="ico icoEdtPf"></span>
				</div>
				<?} else {?>
				<?}?>
		</div>
		<div class="wrpDpNamePf">
			<span class="dpNamePf clTxtPf fs13 cutTxt"><? echo $data['userdata']['displayname'];?></span>
             
			<div class="wrpIcoPvPf">
            <?
             
             if($data['userdata']['publish']==0){
             
             ?>
				<span class="ico icoPvPf"></span>
             <?}?>
			</div>
            <div class="wrpCtcPf">
                <? if($data['userdata']['facebook']){?>
				<div class="ctcPf" title="Facebook" onclick="linkto('<?php if(strpos($data['userdata']['facebook'],"http")===false){$data['userdata']['facebook']='http://'.$data['userdata']['facebook'];} echo $data['userdata']['facebook'];?>')">
					<span class="ico icoFbPf"></span>
				</div>
                <? }?>
                <? if($data['userdata']['twitter']){?>
				<div class="ctcPf" title="Twitter" onclick="linkto('<?php if(strpos($data['userdata']['twitter'],"http")===false){$data['userdata']['twitter']='http://'.$data['userdata']['twitter'];} echo $data['userdata']['twitter'];?>')">
					<span class="ico icoTwtPf"></span>
				</div>
                 <? }?>
                 <? if($data['userdata']['googleplus']){?>
				<div class="ctcPf" title="Google Plus" onclick="linkto('<?php if(strpos($data['userdata']['googleplus'],"http")===false){$data['userdata']['googleplus']='http://'.$data['userdata']['googleplus'];} echo $data['userdata']['googleplus'];?>')">
					<span class="ico icoGpPf"></span>
				</div>
                 <? }?>
                 <? if($data['userdata']['website']){?>
				<div class="ctcPf" title="Website" onclick="linkto('<?php if(strpos($data['userdata']['website'],"http")===false){$data['userdata']['website']='http://'.$data['userdata']['website'];} echo $data['userdata']['website'];?>')" >
					<span class="ico icoLnkPf"></span>
				</div>
                 <? }?>
			</div>
		</div>
		<div class="wrpLvlLcPft clTxt3 fs07">
			<span class="lvlPf">Beginner</span>
			<div class="lctPf divLctPf">
				<span class="ico icoMapPf"></span>
				<span class="lctPf spnLctPf cutTxt"><? if($data['userdata']['state']){echo $data['userdata']['state'].',';}?> <? if($data['userdata']['countryname']){echo $data['userdata']['countryname'];}?></span>
			</div>
		</div>
	</div>
	<div class="wrpBtmCovPf">
		<div class="wrpFullPf" onclick="openfullprofile()" title="Full Profile">
			<span class="ico icoFullPf"></span>
		</div>
	</div>
</div>

<? if(defined('gameshow')&&gameshow==1){?>
<div class="wrpGamePf clBg1 clearfix">
    <div class="wrpRank">
        <span class="clBg3 clTxt1 fs03 boldGen">Level : <em class="fs07"><? echo $data['myscore']['level'];?></em></span>
        <span class="clBg3 clTxt1 fs03 boldGen">Rank : <em class="fs07"><? echo $data['myscore']['ranks'];?></em></span>
    </div>
    <div class="wrpOutBadgeProfile">
        <div class="wrprBadgeProfile clearfix">
        
        <? if(count($data['badge'])){
             foreach($data['badge'] as $valuebadge)
             {
        ?>
            <div class="wrpBadgeProfile">
                <img alt="img" src="<?=$valuebadge['img']?>" class="">
                <span class="clTxt1 fs02"><?=$valuebadge['name']?></span>
            </div>
        <?
             }
        }?>
         <!--   <div class="wrpBadgeProfile">
                <img alt="img" src="/img/testtn2.jpg" class="">
                <span class="clTxt1 fs02">Badge Name</span>
            </div>
            <div class="wrpBadgeProfile">
                <img alt="img" src="/img/testtn3.jpg" class="">
                <span class="clTxt1 fs02">Badge Name</span>
            </div>
            <div class="wrpBadgeProfile">
                <img alt="img" src="/img/testtn4.jpg" class="">
                <span class="clTxt1 fs02">Badge Name</span>
            </div>
            -->
        </div>
    </div>
</div>
<?}?>